package com.supermarket.exception;

public class UserException extends RuntimeException {
    public Integer userId;

    // 默认构造函数
    public UserException() {
        super();
    }

    // 带错误信息的构造函数
    public UserException(String message) {
        super(message);
    }

    // 带错误信息和原因的构造函数
    public UserException(String message, Throwable cause) {
        super(message, cause);
    }

    // 带原因的构造函数
    public UserException(Throwable cause) {
        super(cause);
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }
}